package com.dxx.cloud.admin.module.request;

import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.Valid;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import org.hibernate.validator.constraints.NotEmpty;

import java.util.Date;
import java.util.List;

@Schema(description = "添加订单请求体")
@Data
public class OrderAddRequest {

    private Long id;

    @Schema(description="客户id",example="1")
    private Long customerId;

    @Schema(description="完成状态")
    private Integer completeStatus;

    @Schema(description="描述",example = "这是订单描述")
    private String remarks;

    /**
     * 订单编号
     */
    private String serialNo;

    @Schema(description="地址",example="中国上海黄埔1号")
    private String address;


    @Schema(description="商品规格列表")
    @NotEmpty
    @Valid
    List<OrderAddGoodsModule> goodsList;

    @Schema(description="原始的作废订单",example="1")
    private Integer invalidOrderId;

    @Schema(description="创建者",example="admin")
    private String creator;

    @JsonIgnore
    @Schema(description="创建日期",example="2020-01-01")
    private Date created;

    @JsonIgnore
    @Schema(description="支付日期",example="2020-01-01")
    private Date payTime;

    @Schema(description="操作者",example="admin")
    private String operator;


}
